02. MongoDB

JavaND#305 C03 L03 A02 Mongo DB

Summary

In MongoDB, data is organized into documents. Documents are a collection of key and value pairs. The values can be scalar types like numbers, dates and strings. The values can also be arrays, other documents or arrays of documents.

Documents are organized into collections. A set of collections is organized into a database.

Documents

A record in MongoDB is a document, which is a data structure composed of field and value pairs. MongoDB documents are similar to JSON objects. The values of fields may include other documents, arrays, and arrays of documents.

The advantages of using documents are:
Documents (i.e. objects) correspond to native data types in many programming languages.
Embedded documents and arrays reduce need for expensive joins.

Additional Resources:

MongoDB
JSON Spec
BSON

Exercise

Task List:

Task Feedback:

Congratulations! You have a working installation of MongoDB server on your local workstation.